<template>
  <div class="container">
    <van-nav-bar title="论坛" left-text="返回" left-arrow @click-left="back" />
    <van-tabs v-model="active">
      <van-tab v-for="item in list" :key="item.id" :title="item.name"
        ><div style="height: 73vh">暂未开通，还请谅解</div>
        <van-button
          type="primary"
          style="width: 94%; margin-left: 3%"
          plain
          size="small"
          :to="{ name: 'Fatie', params: { id: item.id, name: item.name } }"
          >我要发布</van-button
        ></van-tab
      >
    </van-tabs>
  </div>
</template>

<script>
import { loadBan } from "../services/luntan";
export default {
  data() {
    return {
      active: 2,
      list: [],
    };
  },
  async created() {
    const res = await loadBan();
    console.log(res.data);
    this.list = res.data;
  },
  methods: {
    back() {
      window.history.go(-1);
    },
  },
};
</script>

<style>
</style>